.box{
    width:100px;
    height:100px;
    background-color: red; 
    transform-origin:50% 50%;
    /* transform:rotate(50deg); */
    animation:rotateZ 2s linear infinite;
    
}
@keyframes rotateZ{
    from{
        transform: translate(0px)rotateZ(0deg);
        
    }
  
    to{
        transform: translate(300px)rotateZ(360deg);
    }
}